﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.Text;
using PiscoSourSOAPServices.Persistencia;
using PiscoSourDominio;

namespace PiscoSourSOAPServices
{
    // NOTE: You can use the "Rename" command on the "Refactor" menu to change the class name "Restaurantes" in code, svc and config file together.
    public class Restaurantes : IRestaurantes
    {
        private RestauranteDAO restauranteDAO = null;
        private RestauranteDAO RestauranteDAO
        {
            get
            {
                if (restauranteDAO == null)
                    restauranteDAO = new RestauranteDAO();
                return restauranteDAO;
            }
        }

        public List<Restaurante> ListarRestaurantes()
        {
            return RestauranteDAO.ListarRestaurantes().ToList();
        }
    }
}
